package com.sans.start;

import org.junit.Test;

/**
 * @author Sans
 */
public class PrintTest {
    @Test
    public void println() {
        System.out.println("111111");
        System.out.println("\n\n");
        System.out.println("222222");
    }
    @Test
    public void print(){
        System.out.print("1");
        System.out.print("2");
    }
    @Test
    public void printf(){
        System.out.printf("我叫%s,今年%d岁，是一个%s人，工资是%.2f！\n","古尔丹",103,"兽",3500.78);
    }
    @Test
    public void plus(){
        System.out.println(1+2+3+4+5+6);
        System.out.println(1+2+3+"4"+5+6);
        System.out.println("1"+2+3+"4"+5+6);
    }
    @Test
    public void specialCharacters(){
        System.out.println("1111\n2222");
        System.out.println("1111\t2222");
        System.out.println("\u4f60\u597d");
    }
    @Test
    public void escape(){
        System.out.println("1111\\n2222");
        System.out.println("1111\\t2222");
        System.out.println("1111\\2222");
        System.out.println("\"");
    }
}
